﻿using System;
using System.Linq;
using System.Collections.Generic;
using System.Text;

namespace MobileEntities.Logic
{
    public class Util
    {
        public static bool ArrayEquals(string[] a, string[] b)
        {
            if (a == null && b == null) return true;
            if (a != null && a.Length == 0 && b == null) return true;
            if (a == null && b != null && b.Length == 0) return true;
            if (a == null || b == null) return false; // One has length >0
            if (a.Length != b.Length) return false;
            for (int i = 0; i < a.Length; i++)
            {
                if (!a[i].Equals(b[i])) return false;
            }
            return true;
        }
    }
}
